import $axios from '../utils/request';
// 查询列表数据
export const getExhibitionPage = (params) => {
    return $axios({
        url: '/exhibition/page',
        method: 'get',
        params
    })
}

// 删除数据接口
export const deleteExhibition = (ids) => {
    return $axios({
        url: '/exhibition',
        method: 'delete',
        params: { ids }
    })
}

// 修改数据接口
export const editExhibition = (params) => {
    return $axios({
        url: '/exhibition',
        method: 'put',
        data: { ...params }
    })
}

// 新增数据接口
export const addExhibition = (params) => {
    return $axios({
        url: '/exhibition',
        method: 'post',
        data: { ...params }
    })
}

// 查询详情接口
export const queryExhibitionById = (id) => {
    return $axios({
        url: `/exhibition/${id}`,
        method: 'get'
    })
}

// 批量起售禁售
export const exhibitionStatusByStatus = (params) => {
    return $axios({
        url: `/exhibition/status/${params.status}`,
        method: 'post',
        params: { ids: params.ids }
    })
}
